<template>
  <div>
    <HeroBanner />

    <section class="container features-section">
      <div class="section-header">
        <h2>为什么选择意数未来</h2>
        <p class="section-subtitle">我们提供专业、合规、透明的金融服务解决方案</p>
      </div>
      
      <div class="features-grid grid cols-3">
        <div class="feature-card card">
          <div class="feature-card-icon">
            <svg width="40" height="40" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round">
              <path d="M17 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2"></path>
              <circle cx="9" cy="7" r="4"></circle>
              <path d="M23 21v-2a4 4 0 0 0-3-3.87"></path>
              <path d="M16 3.13a4 4 0 0 1 0 7.75"></path>
            </svg>
          </div>
          <h3 class="feature-card-title">专业团队</h3>
          <p class="feature-card-description">深耕本地金融生态，熟悉银行/机构审批逻辑与材料清单，缩短放款周期。</p>
        </div>
        
        <div class="feature-card card">
          <div class="feature-card-icon">
            <svg width="40" height="40" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round">
              <path d="M22 11.08V12a10 10 0 1 1-5.93-9.14"></path>
              <polyline points="22 4 12 14.01 9 11.01"></polyline>
            </svg>
          </div>
          <h3 class="feature-card-title">合规透明</h3>
          <p class="feature-card-description">标准化服务流程与报价，签署服务协议，拒绝隐形费用。</p>
        </div>
        
        <div class="feature-card card">
          <div class="feature-card-icon">
            <svg width="40" height="40" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round">
              <rect x="3" y="11" width="18" height="11" rx="2" ry="2"></rect>
              <path d="M7 11V7a5 5 0 0 1 10 0v4"></path>
            </svg>
          </div>
          <h3 class="feature-card-title">隐私保护</h3>
          <p class="feature-card-description">严控信息采集与使用范围，仅用于金融评估与方案匹配。</p>
        </div>
      </div>
    </section>
  </div>
</template>

<script setup lang="ts">
import HeroBanner from '@/components/HeroBanner.vue';
</script>

<style scoped>
.features-section {
  padding: 60px 0 80px;
  position: relative;
}

.section-header {
  text-align: center;
  margin-bottom: 50px;
}

.section-header h2 {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 12px;
  color: var(--text);
  position: relative;
  display: inline-block;
}

.section-header h2::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: linear-gradient(135deg, #0ea5e9, #a78bfa);
  border-radius: 2px;
}

.section-subtitle {
  font-size: 16px;
  color: var(--muted);
  max-width: 600px;
  margin: 0 auto;
}

.features-grid {
  gap: 32px;
}

.feature-card {
  padding: 32px;
  border-radius: 20px;
  text-align: center;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(0, 0, 0, 0.06);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(135deg, #0ea5e9, #a78bfa);
  transform: scaleX(0);
  transition: transform 0.3s ease;
  transform-origin: left;
}

.feature-card:hover::before {
  transform: scaleX(1);
}

.feature-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.feature-card-icon {
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.1), rgba(167, 139, 250, 0.1));
  border-radius: 50%;
  color: #0ea5e9;
  transition: all 0.3s ease;
}

.feature-card:hover .feature-card-icon {
  transform: scale(1.1);
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.2), rgba(167, 139, 250, 0.2));
}

.feature-card-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text);
}

.feature-card-description {
  font-size: 15px;
  line-height: 1.6;
  color: var(--muted);
}

/* 为每个卡片添加动画延迟 */
.feature-card:nth-child(1) {
  animation: fadeInUp 0.6s ease-out 0.1s both;
}

.feature-card:nth-child(2) {
  animation: fadeInUp 0.6s ease-out 0.3s both;
}

.feature-card:nth-child(3) {
  animation: fadeInUp 0.6s ease-out 0.5s both;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 900px) {
  .features-section {
    padding: 40px 0 60px;
  }
  
  .section-header h2 {
    font-size: 28px;
  }
  
  .features-grid {
    gap: 24px;
  }
  
  .feature-card {
    padding: 24px;
  }
}
</style>